package com.atguigu.eduservice.service;

import com.atguigu.eduservice.entity.EduComment;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Map;

/**
 * <p>
 * 评论 服务类
 * </p>
 *
 * @author Y丶HS练习谷粒商城
 * @since 2022-10-09
 */
public interface EduCommentService extends IService<EduComment> {
    /**
     * 根据课程id获取评论信息
     * @param commentPage 分页条件
     * @param courseId 课程id
     * @return
     */
    Map<String, Object> listEntityByCourseId(Page<EduComment> commentPage, String courseId);

    /**
     * 保存评论
     * @param entity
     * @param token
     */
    void saveEntity(EduComment entity, String token);
}
